package com.ybear.ybmediax.audio;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;

@Retention(RetentionPolicy.CLASS)
public @interface EncodingType {
    /** Invalid audio data format */
    int ENCODING_INVALID = 0;
    /** Default audio data format */
    int ENCODING_DEFAULT = 1;

    // These values must be kept in sync with core/jni/android_media_AudioFormat.h
    // Also sync av/services/audiopolicy/managerdefault/ConfigParsingUtils.h
    /** Audio data format: PCM 16 bit per sample. Guaranteed to be supported by devices. */
    int ENCODING_PCM_16BIT = 2;
    /** Audio data format: PCM 8 bit per sample. Not guaranteed to be supported by devices. */
    int ENCODING_PCM_8BIT = 3;
    /** Audio data format: single-precision floating-point per sample */
    int ENCODING_PCM_FLOAT = 4;
    /** Audio data format: AC-3 compressed */
    int ENCODING_AC3 = 5;
    /** Audio data format: E-AC-3 compressed */
    int ENCODING_E_AC3 = 6;
    /** Audio data format: DTS compressed */
    int ENCODING_DTS = 7;
    /** Audio data format: DTS HD compressed */
    int ENCODING_DTS_HD = 8;
    /** Audio data format: MP3 compressed */
    int ENCODING_MP3 = 9;
    /** Audio data format: AAC LC compressed */
    int ENCODING_AAC_LC = 10;
    /** Audio data format: AAC HE V1 compressed */
    int ENCODING_AAC_HE_V1 = 11;
    /** Audio data format: AAC HE V2 compressed */
    int ENCODING_AAC_HE_V2 = 12;

    /** Audio data format: compressed audio wrapped in PCM for HDMI
     * or S/PDIF passthrough.
     * IEC61937 uses a stereo stream of 16-bit samples as the wrapper.
     * So the channel mask for the track must be {@link ChannelType#CHANNEL_OUT_STEREO}.
     * Data should be written to the stream in a short[] array.
     * If the data is written in a byte[] array then there may be endian problems
     * on some platforms when converting to short internally.
     */
    int ENCODING_IEC61937 = 13;
    /** Audio data format: DOLBY TRUEHD compressed
     **/
    int ENCODING_DOLBY_TRUEHD = 14;
    /** Audio data format: AAC ELD compressed */
    int ENCODING_AAC_ELD = 15;
    /** Audio data format: AAC xHE compressed */
    int ENCODING_AAC_XHE = 16;
    /** Audio data format: AC-4 sync frame transport format */
    int ENCODING_AC4 = 17;
    /** Audio data format: E-AC-3-JOC compressed
     * E-AC-3-JOC streams can be decoded by downstream devices supporting {@link #ENCODING_E_AC3}.
     * Use {@link #ENCODING_E_AC3} as the AudioX encoding when the downstream device
     * supports {@link #ENCODING_E_AC3} but not this.
     **/
    int ENCODING_E_AC3_JOC = 18;
    /** Audio data format: Dolby MAT (Metadata-enhanced Audio Transmission)
     * Dolby MAT bitstreams are used to transmit Dolby TrueHD, channel-based PCM, or PCM with
     * metadata (object audio) over HDMI (e.g. Dolby Atmos content).
     **/
    int ENCODING_DOLBY_MAT = 19;
}